package com.sumainfor.wx.system.epc.service;

import com.sumainfor.wx.system.epc.dao.CommodityMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * 功能描述:
 *
 * @Auther: zhlu
 * @Date: 2019/6/12 20:52
 * @Description:
 */
@Service
public class CommodityService {

    @Autowired
    CommodityMapper CommodityMapper;

    /**
     * 根据商品类型查询商品的名称和编号
     * @param params
     * @return
     */
    public List<Map<String, Object>> getCommodityByComType(Map<String, Object> params) {
        return CommodityMapper.getCommodityByComType(params);
    }
    /**
     * 根据商品编号查询商品对应的规格名称和编号
     * @param params
     * @return
     */
    public List<Map<String, Object>> getCommoditySpeByComId(Map<String, Object> params) {
        return CommodityMapper.getCommoditySpeByComId(params);
    }
    /**
     * 根据规格编号查询对应的型号和单位
     * @param params
     * @return
     */
    public List<Map<String, Object>> getCommoditySpeMoByComSpeId(Map<String, Object> params) {
        return CommodityMapper.getCommoditySpeMoByComSpeId(params);
    }

}
